package com.edu.admin.entity;


import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Transient;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;

import com.edu.admin.common.BaseEntity;

/**
 * 用户表实体
 * 
 * @author Wangjiong
 * 
 */
@Table(name = "sys_user")
public class SysUser extends BaseEntity{

	
	/**
	 * 
	 */
	private static final long serialVersionUID = -2419304205303687275L;
	/**
	 * 学生id
	 * 
	 */
	@Id
	@GeneratedValue(generator = "JDBC")
	private Long userId;
	/**
	 * 登录账号
	 * 
	 */
	private String account;
	/**
	 * 用户名
	 * 
	 */
	@NotBlank(message = "用户名不能为空")
	private String userName;
	/**
	 * 用户名拼音
	 * 
	 */
	private String pinyin;
	/**
	 * 用户密码
	 * 
	 */
	private String password;
	/**
	 * 用户电话
	 * 
	 */
	private String phone;
	/**
	 * 学段id
	 * 
	 */
	private Long phaseId;
	/**
	 * 学校id
	 * 
	 */
	private Long schoolId;
	/**
	 * 班级id
	 * 
	 */
	private Long classesId;
	/**
	 * 用户生日
	 * 
	 */
	private String birthday;
	/**
	 * 性别 0：男    1：女
	 * 
	 */
	@Min(value = 0, message = "性别不能为空") 
	private String gender;
	/**
	 * 用户类型1教师2学生3家长4校长
	 * 
	 */
	private Integer type;
	/**
	 * 头像图链接
	 * 
	 */
	private String imageUrl;
	/**
	 * 省份
	 * 
	 */
	private String provinceCode;
	/**
	 * 城市
	 * 
	 */
	private String cityCode;
	/**
	 * 地区
	 * 
	 */
	private String districtCode;
	/**
	 * 地址
	 * 
	 */
	private String address;
	/**
	 * 角色
	 * 
	 */
	private Long roleId;
	/**
	 * 用户简介
	 * 
	 */
	private String intro;
	/**
	 * 学籍号
	 * 
	 */
	private String studentNo;
	/**
	 * 教师证号
	 * 
	 */
	private String teacherNo;
	/**
	 * 微信绑定码
	 * 
	 */
	private String openid;
	/**
	 * 积分
	 * 
	 */
	private Integer point;
	/**
	 * 重名备注
	 * 
	 */
	private String userRemark;
	/**
	 * 是否使用
	 * 
	 */
	private Integer useType;
	/**
	 * 学校名称
	 * 
	 */
	@Transient
	private String schoolName;
	/**
	 * 班级名称
	 * 
	 */
	@Transient
	private String classesName;
	/**
	 * 年级id
	 * 
	 */
	@Transient
	private Long gradeId;
	/**
	 * 年级名称
	 * 
	 */
	@Transient
	private String gradeName;
	/**
	 * 学段名称
	 * 
	 */
	@Transient
	private String phaseName;
	/**
	 * 角色名称
	 * 
	 */
	@Transient
	private String RoleName;
	/**
	 * 学科数组
	 * 
	 */
	@Transient
	private Long[] subjects;
	/**
	 * 省份名称
	 * 
	 */
	@Transient
	private String provinceName;
	/**
	 * 城市名称
	 * 
	 */
	@Transient
	private String cityName;
	/**
	 * 地区名称
	 * 
	 */
	@Transient
	private String districtName;
	
	
	public Long getUserId() {
		return userId;
	}
	public void setUserId(Long userId) {
		this.userId = userId;
	}
	public String getAccount() {
		return account;
	}
	public void setAccount(String account) {
		this.account = account;
	}
	public String getUserName() {
		return userName;
	}
	public void setUserName(String userName) {
		this.userName = userName;
	}
	public String getPinyin() {
		return pinyin;
	}
	public void setPinyin(String pinyin) {
		this.pinyin = pinyin;
	}
	public String getPassword() {
		return password;
	}
	public void setPassword(String password) {
		this.password = password;
	}
	public String getPhone() {
		return phone;
	}
	public void setPhone(String phone) {
		this.phone = phone;
	}
	public Long getPhaseId() {
		return phaseId;
	}
	public void setPhaseId(Long phaseId) {
		this.phaseId = phaseId;
	}
	public Long getSchoolId() {
		return schoolId;
	}
	public void setSchoolId(Long schoolId) {
		this.schoolId = schoolId;
	}
	public Long getClassesId() {
		return classesId;
	}
	public void setClassesId(Long classesId) {
		this.classesId = classesId;
	}
	public String getBirthday() {
		return birthday;
	}
	public void setBirthday(String birthday) {
		this.birthday = birthday;
	}
	public String getGender() {
		return gender;
	}
	public void setGender(String gender) {
		this.gender = gender;
	}
	public Integer getType() {
		return type;
	}
	public void setType(Integer type) {
		this.type = type;
	}
	public String getImageUrl() {
		return imageUrl;
	}
	public void setImageUrl(String imageUrl) {
		this.imageUrl = imageUrl;
	}
	public String getProvinceCode() {
		return provinceCode;
	}
	public void setProvinceCode(String provinceCode) {
		this.provinceCode = provinceCode;
	}
	public String getCityCode() {
		return cityCode;
	}
	public void setCityCode(String cityCode) {
		this.cityCode = cityCode;
	}
	public String getDistrictCode() {
		return districtCode;
	}
	public void setDistrictCode(String districtCode) {
		this.districtCode = districtCode;
	}
	public String getAddress() {
		return address;
	}
	public void setAddress(String address) {
		this.address = address;
	}
	public Long getRoleId() {
		return roleId;
	}
	public void setRoleId(Long roleId) {
		this.roleId = roleId;
	}
	public String getIntro() {
		return intro;
	}
	public void setIntro(String intro) {
		this.intro = intro;
	}
	public String getStudentNo() {
		return studentNo;
	}
	public void setStudentNo(String studentNo) {
		this.studentNo = studentNo;
	}
	public String getOpenid() {
		return openid;
	}
	public void setOpenid(String openid) {
		this.openid = openid;
	}
	public Integer getPoint() {
		return point;
	}
	public void setPoint(Integer point) {
		this.point = point;
	}
	public String getUserRemark() {
		return userRemark;
	}
	public void setUserRemark(String userRemark) {
		this.userRemark = userRemark;
	}
	public Integer getUseType() {
		return useType;
	}
	public void setUseType(Integer useType) {
		this.useType = useType;
	}
	public String getSchoolName() {
		return schoolName;
	}
	public void setSchoolName(String schoolName) {
		this.schoolName = schoolName;
	}
	public String getClassesName() {
		return classesName;
	}
	public void setClassesName(String classesName) {
		this.classesName = classesName;
	}
	public Long getGradeId() {
		return gradeId;
	}
	public void setGradeId(Long gradeId) {
		this.gradeId = gradeId;
	}
	public String getGradeName() {
		return gradeName;
	}
	public void setGradeName(String gradeName) {
		this.gradeName = gradeName;
	}
	public String getTeacherNo() {
		return teacherNo;
	}
	public void setTeacherNo(String teacherNo) {
		this.teacherNo = teacherNo;
	}
	public String getPhaseName() {
		return phaseName;
	}
	public void setPhaseName(String phaseName) {
		this.phaseName = phaseName;
	}
	public String getRoleName() {
		return RoleName;
	}
	public void setRoleName(String roleName) {
		RoleName = roleName;
	}
	public Long[] getSubjects() {
		return subjects;
	}
	public void setSubjects(Long[] subjects) {
		this.subjects = subjects;
	}
	public String getProvinceName() {
		return provinceName;
	}
	public void setProvinceName(String provinceName) {
		this.provinceName = provinceName;
	}
	public String getCityName() {
		return cityName;
	}
	public void setCityName(String cityName) {
		this.cityName = cityName;
	}
	public String getDistrictName() {
		return districtName;
	}
	public void setDistrictName(String districtName) {
		this.districtName = districtName;
	}
	

}
